<template>
  <div class="recommonded">
    <div class="title">
      <i-icon v-if="title==='已关注'" type="collection" size="24" i-class="recommendedStar" />
      <img v-else src="../../../../static/images/doc.png" />
      <span class="recommendedTitle">{{title}}</span>
    </div>
    <!-- <ul class='clearfix'>
      <li v-for="(doctor, index) in recommondList" :key="index" class="recommondDoctorList">
        <div class="container">
          <i-avatar
            i-class="doctorAvatar"
            shape="cirlce"
            size="large"
            src="https://pic1.zhimg.com/v2-e9524bd287b70e64915a2d155f014072_is.jpg"
          ></i-avatar>
          <div class="doctorDetail">123123123</div>
          <div>78913213</div>
        </div>
      </li>
    </ul>-->
    <ul class="recommondDoctorList">
      <li>
        <div class="container">
          <img src="../../../../static/images/user1.png" />
          <h3 class="doctorDetail">
            <span>刘妙春</span>
            <i>主任医师</i>
          </h3>
          <p>北大医院神经外科</p>
        </div>
      </li>
      <li>
        <div class="container">
          <img src="../../../../static/images/user2.png" />
          <h3 class="doctorDetail">
            <span>李民</span>
            <i>主任医师</i>
          </h3>
          <p>北大医院神经外科</p>
        </div>
      </li>
      <li>
        <div class="container">
          <img src="../../../../static/images/user3.png" />
          <h3 class="doctorDetail">
            <span>夏群</span>
            <i>主任医师</i>
          </h3>
          <p>北大医院神经外科</p>
        </div>
      </li>
      <li>
        <div class="container">
          <img src="../../../../static/images/user3.png" />
          <h3 class="doctorDetail">
            <span>夏群</span>
            <i>主任医师</i>
          </h3>
          <p>北大医院神经外科</p>
        </div>
      </li>
    </ul>
  </div>
</template>

<script>
export default {
  name: "recommonded",
  props: {
    title: String,
    iconType: String
  },
  data() {
    return {
      recommondList: [1, 2, 3, 4]
    };
  }
};
</script>

<style lang="scss" scoped>
.clearfix:after,
.clearfix:before {
  content: "";
  display: table;
}
.clearfix:after {
  clear: both;
}
.recommonded {
  width: 100%;
  overflow: hidden;
  .title {
    width: 100%;
    height: 80rpx;
    background-color: #f3f1f4;
    padding: 0 20rpx;
    position: relative;
    display: flex;
    align-items: center;
    .recommendedTitle {
      margin-left: 12rpx;
      font-size: 30rpx;
    }
    img {
      width: 40rpx;
      height: 40rpx;
    }
  }
  // .recommondDoctorList {
  //   float: left;
  //   width: 100%;
  //   padding: 20rpx 0;
  //   overflow: hidden;
  //   .container {
  //     text-align: center;
  //     .doctorDetail {
  //       margin-top: 20rpx;
  //     }
  //   }
  // }
}
.recommondDoctorList {
  width: 100%;
  padding: 20rpx 0;
  overflow: hidden;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  background-color: #ffffff;
  li {
    width: 33.3333333%;
    padding-top: 30rpx;
    display: flex;
    align-items: center;
    justify-content: center;
    .container {
      text-align: center;
      img {
        width: 120rpx;
        height: 120rpx;
        border-radius: 60rpx;
      }
      .doctorDetail {
        padding-top: 2rpx;
        width: 100%;
        display: flex;
        justify-content: center;
        align-items: center;
        font-size: 24rpx;
        color: #000000;
        span {
          margin-right: 14rpx;
        }
      }
      p {
        padding-top: 4rpx;
        font-size: 24rpx;
        color: #6075de;
      }
    }
  }
}
</style>
<style lang="scss">
.recommendedStar {
  height: 60rpx !important;
  line-height: 60rpx !important;
  vertical-align: baseline !important;
}
</style>